package edu.hwadee.BEIS.entity;
// default package

import java.sql.Timestamp;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;
import org.hibernate.annotations.GenericGenerator;

/**
 * ProjectProgress entity. @author MyEclipse Persistence Tools
 */
@Entity
@Table(name = "project_progress", catalog = "beis")

public class ProjectProgress implements java.io.Serializable {

	// Fields

	private Integer projectProgressId;
	private ProjectDeclare projectDeclare;
	private String declarer;
	private String declarerPhone;
	private Float currentProgress;
	private String completedFile;
	private Timestamp reportTime;

	// Constructors

	/** default constructor */
	public ProjectProgress() {
	}

	/** full constructor */
	public ProjectProgress(ProjectDeclare projectDeclare, String declarer, String declarerPhone, Float currentProgress,
			String completedFile, Timestamp reportTime) {
		this.projectDeclare = projectDeclare;
		this.declarer = declarer;
		this.declarerPhone = declarerPhone;
		this.currentProgress = currentProgress;
		this.completedFile = completedFile;
		this.reportTime = reportTime;
	}

	// Property accessors
	@GenericGenerator(name = "generator", strategy = "increment")
	@Id
	@GeneratedValue(generator = "generator")

	@Column(name = "project_progress_id", unique = true, nullable = false)

	public Integer getProjectProgressId() {
		return this.projectProgressId;
	}

	public void setProjectProgressId(Integer projectProgressId) {
		this.projectProgressId = projectProgressId;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "project_declare_id", nullable = false)

	public ProjectDeclare getProjectDeclare() {
		return this.projectDeclare;
	}

	public void setProjectDeclare(ProjectDeclare projectDeclare) {
		this.projectDeclare = projectDeclare;
	}

	@Column(name = "declarer", nullable = false, length = 10)

	public String getDeclarer() {
		return this.declarer;
	}

	public void setDeclarer(String declarer) {
		this.declarer = declarer;
	}

	@Column(name = "declarer_phone", nullable = false, length = 20)

	public String getDeclarerPhone() {
		return this.declarerPhone;
	}

	public void setDeclarerPhone(String declarerPhone) {
		this.declarerPhone = declarerPhone;
	}

	@Column(name = "current_progress", nullable = false, precision = 12, scale = 0)

	public Float getCurrentProgress() {
		return this.currentProgress;
	}

	public void setCurrentProgress(Float currentProgress) {
		this.currentProgress = currentProgress;
	}

	@Column(name = "completed_file", nullable = false, length = 50)

	public String getCompletedFile() {
		return this.completedFile;
	}

	public void setCompletedFile(String completedFile) {
		this.completedFile = completedFile;
	}

	@Column(name = "report_time", nullable = false, length = 19)

	public Timestamp getReportTime() {
		return this.reportTime;
	}

	public void setReportTime(Timestamp reportTime) {
		this.reportTime = reportTime;
	}

}